import ajax from './ajax';

export const BASE_URL = 'https://shop.rzkeji.com/api/';
/* export var FILE_URL = 'http://rzkeji.oss-cn-shenzhen.aliyuncs.com/web/peoplesAssociation/'; */


/* export const bindAccount = (params) => ajax(BASE_URL + 'user/bindAccount', params,'POST') */
/* export const getInviteUserWay = (params) => ajax(BASE_URL + 'getInviteUserWay', params,'GET') */


//微信登录
export const wxAppLogin = (params) => ajax(BASE_URL + 'auth/wxAppLogin', params,'POST')
//获取用户个人信息
export const getUserInfos = (params) => ajax(BASE_URL + 'ucenter/getUserInfo', params);
//获取定位地址信息
export const getLocationInfos = (params) => ajax('https://apis.map.qq.com/ws/geocoder/v1/', params,'GET');
//获取首页广告图
export const getAdvertImg = (params) => ajax(BASE_URL + 'other/getAdvertImg', params,'GET');
//获取首页专栏商品
export const getSectionGoodsList = (params) => ajax(BASE_URL + 'goods/getSectionGoodsList', params,'GET');
//获取首页推荐商品
export const getRecommendGoodsList = (params) => ajax(BASE_URL + 'goods/getRecommendGoodsList', params,'GET');
//获取商品详情
export const getGoodsDetails = (params) => ajax(BASE_URL + 'goods/getGoodsDetails', params,'GET');
//获取购物车列表
export const getShopCart = (params) => ajax(BASE_URL + 'goods/getShopCart', params,'GET');
//添加购物车
export const addShopCart = (params) => ajax(BASE_URL + 'goods/addShopCart', params,'POST')
//创建订单
export const submitOrder = (params) => ajax(BASE_URL + 'order/submitOrder', params,'POST')
//获取分类列表
export const getSectionClassifyList = (params) => ajax(BASE_URL + 'goods/getSectionClassifyList', params,'GET')
//获取多级分类列表
export const getSectionClassifyTwoList = (params) => ajax(BASE_URL + 'goods/getSectionClassifyTwoList', params,'GET')
//通过分类id获取商品列表
export const getGoodsListByClassifyId = (params) => ajax(BASE_URL + 'goods/getGoodsListByClassifyId', params,'GET')


//获取购物车列表
// export const getShopCart = (params) => ajax(BASE_URL + 'mall/getShopCart', params,'GET')
//删除购物车的商品
export const deleteShopCart = (params) => ajax(BASE_URL + 'mall/deleteShopCart', params,'POST')

//获取轮播图
export const getBannerList = (params) => ajax(BASE_URL + 'other/getBannerList', params,'GET')
//获取首页功能区按钮
export const getIndexButtonList = (params) => ajax(BASE_URL + 'goods/getGoodsClassify?type=section', params,'GET')

//获取首页专区
export const getIndexAreaList = (params) => ajax(BASE_URL + 'mall/getIndexAreaList', params,'GET')
//获取销售药品用的分类
export const getBuyingClassifyList = (params) => ajax(BASE_URL + 'mall/getBuyingClassifyList', params,'GET')
//获取店铺的药品列表
export const getMerchantMedicineList = (params) => ajax(BASE_URL + 'mall/getMerchantMedicineList', params,'GET')
//搜索药品
export const searchMedicine = (params) => ajax(BASE_URL + 'mall/searchMedicine', params,'GET')
//获取用户的优惠券
export const getUserCoupon = (params) => ajax(BASE_URL + 'ucenter/getUserCoupon', params,'GET')

//获取商品详情
export const getMedicineDetail = (params) => ajax(BASE_URL + 'mall/getMedicineDetail', params,'GET')


//删除收货地址
export const deleteShippingAddress = (params) => ajax(BASE_URL + 'ucenter/deleteShippingAddress', params,'POST')
//获取我的收货地址
export const getShippingAddress = (params) => ajax(BASE_URL + 'ucenter/getShippingAddress', params,'GET')
//新增收货地址
export const newShippingAddress = (params) => ajax(BASE_URL + 'ucenter/newShippingAddress', params,'POST')
//获取关于我们
export const getAboutUs = (params) => ajax(BASE_URL + 'ucenter/getAboutUs', params,'GET')